<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title>share - frm 代理</title>
        <meta content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0" name="viewport"/>
        <meta content="yes" name="apple-mobile-web-app-capable"/>
        <meta content="black" name="apple-mobile-web-app-status-bar-style"/>
        <meta content="telephone=no" name="format-detection"/>
		
		<style>
		html,body {
    color: #333;
    margin: 0;
    font-family: "Myriad Set Pro","Helvetica Neue",Helvetica,Arial,Verdana,sans-serif;
}

* {
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
}

a {
    text-decoration: none;
    color: #000;
}

a, label, button, input, select {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

img {
    border: 0;
}

body {
       background: linear-gradient(to right,#f370af 0,#5515ee 100%);
    color: #666;
}

html, body, div, dl, dt, dd, ol, ul, li, h1, h2, h3, h4, h5, h6, p, blockquote, pre, button, fieldset, form, input, legend, textarea, th, td {

}

a {
    text-decoration: none;
    color: #08acee;
}

button {
    outline: 0;
}

img {
    border: 0;
}

button,input,optgroup,select,textarea {
    margin: 0;
    font: inherit;
    color: inherit;
    outline: none;
}

li {
    list-style: none;
}

a {
    color: #666;
}

.clearfix::after {
    clear: both;
    content: ".";
    display: block;
    height: 0;
    visibility: hidden;
}

.clearfix {
}

.divHeight {
    width: 100%;
    height: 10px;
    background: #f5f5f5;
    position: relative;
    overflow: hidden;
}

.r-line {
    position: relative;
}

.r-line:after {
    content: '';
    position: absolute;
    z-index: 0;
    top: 0;
    right: 0;
    height: 100%;
    border-right: 1px solid #D9D9D9;
    -webkit-transform: scaleX(0.5);
    transform: scaleX(0.5);
    -webkit-transform-origin: 100% 0;
    transform-origin: 100% 0;
}

.b-line {
    position: relative;
}

.b-line:after {
    content: '';
    position: absolute;
    z-index: 2;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    border-bottom: 1px solid #e2e2e2;
    -webkit-transform: scaleY(0.5);
    transform: scaleY(0.5);
    -webkit-transform-origin: 0 100%;
    transform-origin: 0 100%;
}

.aui-flex {
    display: -webkit-box;
    display: -webkit-flex;
    display: flex;
    -webkit-box-align: center;
    -webkit-align-items: center;
    align-items: center;
    position: relative;
}

.aui-flex-box {
    -webkit-box-flex: 1;
    -webkit-flex: 1;
    flex: 1;
    min-width: 0;
    font-size: 14px;
    color: #333;
}

/* 蹇呰甯冨眬鏍峰紡css */
.aui-flexView {
    width: 100%;
    height: 100%;
    margin: 0 auto;
    display: -webkit-box;
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -webkit-flex-direction: column;
    -ms-flex-direction: column;
    flex-direction: column;
}

.aui-scrollView {
    width: 100%;
    height: 100%;
    -webkit-box-flex: 1;
    -webkit-flex: 1;
    -ms-flex: 1;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    position: relative;
}

.aui-navBar {
    height: 44px;
    position: relative;
    display: -webkit-box;
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
    z-index: 555;
    background: #fff;
}

.aui-navBar-item {
    height: 44px;
    min-width: 25%;
    -webkit-box-flex: 0;
    -webkit-flex: 0 0 25%;
    -ms-flex: 0 0 25%;
    flex: 0 0 25%;
    padding: 0 0.9rem;
    display: -webkit-box;
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -webkit-align-items: center;
    -ms-flex-align: center;
    align-items: center;
    font-size: 0.7rem;
    white-space: nowrap;
    overflow: hidden;
    color: #808080;
    position: relative;
}

.aui-navBar-item:first-child {
    -webkit-box-ordinal-group: 2;
    -webkit-order: 1;
    -ms-flex-order: 1;
    order: 1;
    margin-right: -25%;
    font-size: 0.9rem;
    font-weight: bold;
}

.aui-navBar-item:last-child {
    -webkit-box-ordinal-group: 4;
    -webkit-order: 3;
    -ms-flex-order: 3;
    order: 3;
    -webkit-box-pack: end;
    -webkit-justify-content: flex-end;
    -ms-flex-pack: end;
    justify-content: flex-end;
}

.aui-center {
    -webkit-box-ordinal-group: 3;
    -webkit-order: 2;
    -ms-flex-order: 2;
    order: 2;
    display: -webkit-box;
    display: -webkit-flex;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: center;
    -webkit-justify-content: center;
    -ms-flex-pack: center;
    justify-content: center;
    -webkit-box-align: center;
    -webkit-align-items: center;
    -ms-flex-align: center;
    align-items: center;
    height: 44px;
    width: 50%;
    margin-left: 25%;
}

.aui-center-title {
    text-align: center;
    width: 100%;
    white-space: nowrap;
    overflow: hidden;
    display: block;
    text-overflow: ellipsis;
    font-size: 0.95rem;
    color: #333;
}

.icon {
    width: 20px;
    height: 20px;
    display: block;
    border: none;
    float: left;
    background-size: 20px;
    background-repeat: no-repeat;
}

.icon-return {
    background-image: url('');
}

.icon-more {
    background-image: url('');
}

.aui-top-head {
   /* background: #fad477;  */
    width: 100%;
    height: auto;
    overflow: hidden;
}

.aui-title-bg {
    width: 100%;
    height: 7rem;
    position: relative;
    background-size: 100%;
}

.aui-title-bg {
    background-repeat: no-repeat;
}

.aui-invite-box {
    width: 90.333%;
    border-radius: 4px;
    background: #fff;
    padding: 20px;
    margin: -100px auto 0;
}

.aui-invite-title {
    background-repeat: no-repeat;
}

.aui-invite-title {
    width: 100%;
    background-image: url("");
    background-size: 100%;
    text-align: center;
    padding: 10px 0;
}

.aui-invite-title h1 {
    color: #fff;
    font-size: 1.2rem;
    position: relative;
}

.aui-invite-title h1:after {
    content: '';
    position: absolute;
    z-index: 0;
    bottom: -5px;
    left: 60px;
    width: 60%;
    height: 1px;
    border-bottom: 1px solid #ffffff;
    -webkit-transform: scaleY(0.5);
    transform: scaleY(0.5);
    -webkit-transform-origin: 0 100%;
    transform-origin: 0 100%;
}

.aui-invite-title h2 {
    color: #fff;
    font-size: 1.5rem;
    margin-bottom: 0.8rem;    
	margin-top: 0.8rem;
}

.aui-invite-title h2 em {
    font-style: normal;
    background: linear-gradient(to bottom, #ffe700, #feeda7);
    -webkit-background-clip: text;
    color: transparent;
    font-size: 2rem;
}

.aui-invite-title h2 i {
    font-style: normal;
    font-size: 1.4rem;
}

.aui-invite-title p {
    color: #ffffff;
    font-size: 0.85rem;
}

.aui-invite-coupon {
    background-repeat: no-repeat;
}

.aui-invite-coupon {
    margin-top: 1rem;
    width: 100%;
    background-image: url("");
    background-size: 100%;
    text-align: center;
    color: #999999;
    font-size: 0.95rem;
    height: 4rem;
    line-height: 4rem;
    padding-left: 3rem;
}

.aui-invite-coupon em {
    color: #f370af;
    font-style: normal;
}

.aui-button {
    margin-top: 1rem;
    height: 4rem;
}

.aui-button button {
    background-size: 100%;
    width: 100%;
    height: 3.8rem;
    border: none;
    background: none;
    border-radius: 30px;
    color: #fff;
	background: #a543ce;
    box-shadow: 0 0.06rem 1rem 0 #a644cd;
}

.aui-flex-box h2 {
    text-align: center;
    font-size: 1rem;
    color: #ffffff; 
    position: relative;
}

.aui-invite-box-clear {
    margin-top: 0;
    margin-bottom: 1rem;
}

.aui-used-layout {
    background: #fff;
    position: relative;
    overflow: hidden;
}

.aui-grids-item {
    position: relative;
    float: left;
    padding: 10px 10px 12px 10px;
    width: 33.333%;
    box-sizing: border-box;
}



.aui-grids-item-img {
    text-align: center;
    width: 22px;
    height: 22px;
    line-height: 20px;
    display: block;
    color: #fff;
    font-size: 0.95rem;
    background: #f370af;
    border-radius: 100%;
    margin: 0 auto;
    position: relative;
    z-index: 100;
}

.aui-grids-item-text {
    text-align: center;
    width: 100%;
    display: block;
    color: #f370af;
    font-size: 0.7rem;
    padding-top: 5px;
}

.aui-gift {
    width: 90px;
    height: 90px;
}

.aui-gift img {
    width: 100%;
    height: auto;
    display: block;
    border: none;
}

.aui-button-sml {
    background-repeat: no-repeat;
}

.aui-button-sml {
    margin-top: 1rem;
    background-size: 80%;
    width: 80%;
    height: 2.8rem;
    border: none;
    border-radius: 40px;
}

.aui-button-sml button {
    background-size: 100%;
    width: 80%;
    height: 2.8rem;
    border: none;
    background: none;
    border-radius: 30px;
    color: #fff;
	
	color: #fff;
	background: #a543ce;
    box-shadow: 0 0.06rem 1rem 0 #a644cd;
}

.aui-flex-box h4 {
    color: #000;
}

.aui-flex-box h5 {
    color: #999999;
    font-size: 1rem;
}

.aui-footer-bg {
    background-image: url("/preview/1527619/2019-01-10/invite/images/footer-bg.png");
    background-size: 100%;
    background-position: bottom center;
    background-repeat: no-repeat;
    width: 100%;
    height: 5rem;
}

.aui-flex-box h6 {
    color: #454545;
    font-weight: bold;
    text-align: center;
    font-size: 1.1rem;
    position: relative;
}

.aui-flex-box h6:after {
    content: '';
    position: absolute;
    z-index: 0;
    bottom: -10px;
    left: 50%;
    width: 16%;
    margin-left: -8%;
    height: 5px;
    background: #eeecec;
    border-radius: 50px;
}

.aui-flex-box span {
    color: #969696;
    font-size: 0.8rem;
}

.aui-palace {
    padding: 0.9rem 0;
    position: relative;
    overflow: hidden;
}

.aui-palace-grid {
    position: relative;
    float: left;
    padding: 1px;
    width: 33.333%;
    box-sizing: border-box;
    margin-bottom: 10px;
}

.aui-palace-grid-icon {
    margin: 0 auto;
    text-align: center;
}

.aui-palace-grid-icon span {
    color: #424242;
    font-size: 1.3rem;
}

.aui-palace-grid-text {
    display: block;
    text-align: center;
    color: #999999;
    font-size: 0.85rem;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    padding-top: 0.2rem;
}

.aui-palace-grid-text h2 {
    font-size: 0.8rem;
    font-weight: normal;
    color: #999999;
}

.aui-button-btn {
    padding: 0 20px 20px 20px;
}

.aui-button-btn button {
    width: 100%;
    height: 3rem;
    line-height: 3rem;
    color: #fff;
    background: #f14a28;
    border: none;
    box-shadow: 0 8px 19px #fcbdab
}

.aui-user-img {
    width: 45px;
    height: 50px;
    margin-right: 0.5rem;
    position: relative;
}

.aui-vip1 {
    position: absolute;
    top: -8px;
    left: -2px;
    background-image: url("../images/icon-vip1.png");
    background-size: 20px;
    width: 20px;
    height: 20px;
}

.aui-vip2 {
    position: absolute;
    top: -8px;
    left: -2px;
    background-image: url("../images/icon-vip2.png");
    background-size: 20px;
    width: 20px;
    height: 20px;
}

.aui-vip3 {
    position: absolute;
    top: -8px;
    left: -2px;
    background-image: url("../images/icon-vip3.png");
    background-size: 20px;
    width: 20px;
    height: 20px;
}

.aui-user-img img {
    width: 45px;
    height: 45px;
    border-radius: 100%;
    display: block;
    border: none;
}

.aui-arrow {
    color: #fc7701;
    font-size: 1rem;
}

.aui-invite-list .aui-flex-box h4 {
    color: #464646;
    font-weight: normal;
}

.aui-invite-list .aui-flex-box h5 {
    color: #969696;
    font-size: 0.8rem;
    font-weight: normal;
}

.aui-invite-list .aui-flex-box .aui-no1 {
    background: #fdb843;
    border-radius: 3px;
    color: #fff;
    font-style: initial;
    width: 2.5rem;
    text-align: center;
    padding: 0.2rem 0;
    -webkit-transform: skew(-10deg);
}

.aui-invite-list .aui-flex-box .aui-no2 {
    background: #b2b9bf;
    border-radius: 3px;
    color: #fff;
    font-style: initial;
    width: 2.5rem;
    text-align: center;
    padding: 0.2rem 0;
    -webkit-transform: skew(-10deg);
}

.aui-invite-list .aui-flex-box .aui-no3 {
    background: #c88a73;
    border-radius: 3px;
    color: #fff;
    font-style: initial;
    width: 2.5rem;
    text-align: center;
    padding: 0.2rem 0;
    -webkit-transform: skew(-10deg);
}

@media (device-height: 480px) and (-webkit-min-device-pixel-ratio:2) {
    /* 鍏煎iphone4/4s */ .class {
}
}

@media (device-height: 568px) and (-webkit-min-device-pixel-ratio:2) {
    /* 鍏煎iphone5 */ .aui-invite-title {
    padding:25px 0;
}

    .aui-invite-title h2 {
        margin-bottom: 0.4rem;
        font-size: 1.5rem;
		margin-top: 0.4rem;
    }

    .aui-invite-title p {
        font-size: 0.75rem
    }

    .aui-button button {
        height: 3.5rem;
    }

    .aui-invite-coupon {
        margin-top: 0.5rem;
        height: 3rem;
    }

    .aui-flex-box h2:after {
    }
}

@media (device-height: 667px) and (-webkit-min-device-pixel-ratio:2) {
    /* 鍏煎iphone6 */ .class {
}
}

@media (device-height: 736px) and (-webkit-min-device-pixel-ratio:2) {
    /* 鍏煎iphone6 Plus */ .class {
}
}
		</style>
		
		
    </head>
    <body>

        <section class="aui-flexView">

            <section class="aui-scrollView">
                <div class="aui-top-head">
                    <div class="aui-title-bg"></div>
                    <div class="aui-invite-box">
                        <div class="aui-invite-title">
                            <h1>每邀请1位好友</h1>
                            <h2>即得 <em id="Invitation_points" > </em> <i>积分</i></h2>
                            <p>- 被邀请新用户登录以后 您既得积分 -</p>
                        </div>
                        <div class="aui-invite-coupon">
                            <p><em id="Registered_Gift_Time"> - - - </em> 超级会员特权</p>
                        </div>
                        <div class="aui-button"  tapmode="active" onclick="copySet()">
                            <button>邀请好友得积分 多邀多得</button>
							
                        </div>
                    </div>
                    <div class="aui-flex">
                        <div class="aui-flex-box">
                            <h2>简单三步 即得积分</h2>
                        </div>
                    </div>
                    <div class="aui-invite-box aui-invite-box-clear">
                        <div class="aui-used-layout">
                            <a href="javascript:;" class="aui-grids-item">
                                <span class="aui-grids-item-img">1</span>
                                <span class="aui-grids-item-text">
                                    <p>分享活动</p>
                                    <p>给好友</p>
                                </span>
                            </a>
                            <a href="javascript:;" class="aui-grids-item">
                                <span class="aui-grids-item-img">2</span>
                                <span class="aui-grids-item-text">
                                    <p>好友接受</p>
                                    <p>邀请</p>
                                </span>
                            </a>
                            <a href="javascript:;" class="aui-grids-item">
                                <span class="aui-grids-item-img">3</span>
                                <span class="aui-grids-item-text">
                                    <p>好友登录</p>
                                    <p>赠送积分</p>
                                </span>
                            </a>
                        </div>
                    </div>
                    <div class="aui-invite-box aui-invite-box-clear">
                        <div class="aui-flex" style="padding:0">
                            <div class="aui-flex-box">
                                <h4>分享至朋友圈</h4>
                                <div class="aui-button-sml">
                                    <button   tapmode onclick="toshare_poster()">海报分享</button>
                                </div>
                            </div>
                            <div class="aui-gift"   tapmode onclick="shareimage()"  >
                                <img src="">
                            </div>
                        </div>
                    </div>
                </div>


								     

                
            </section>
        </section>

    </body>













<script type="text/javascript" src="../Ryanjs/frame0/jquery.min.js"></script>

<script type="text/javascript" src="../script/api.js" ></script>
<script type="text/javascript" src="../script/doT.js"></script>
<script type="text/javascript">
  var api_url = localStorage.getItem('api_url');
  var dwzapi = '';
  var host = '';

  apiready = function(){
  
    api.parseTapmode();
	
		
	/*	
				api.showProgress({
				    title: '正在加载',
				    text: '请稍等',
				    modal: false
				});
				
 	*/
 
	share();  //获取数据
							// 网络状态
		api.addEventListener({
			name:'offline'
		}, function(ret, err){        

			api.toast({
			msg : '网络连接异常',
			duration : 5000,
			location : 'middle' 
			});

			  

		});

		api.addEventListener({
			name:'online'
		}, function(ret, err){        
		
			  api.toast({
			  msg : '已经连接网络',
			  duration : 2000,
			  location : 'middle' 
			  });
				  
	share();  //获取数据

				  
		});	
  }






    function sharetext() {
	
	
    api.ajax({
        url: 'http://suo.im/api.htm?format=json&url='+dwzapi+'&key=5d79adb9b1a9c71d20af521e@13c666f4f75d74d90b6c11dc3201ee67&expireDate=2050-01-01',
        method: 'get'
    },function(ret, err){
        if (ret) { 

value = app_Invitation_slogans+'：'+ret.url;

        } else {
value = app_Invitation_slogans+'：'+dwzapi;

        }
    });


        var sharedModule = api.require('shareAction');
        sharedModule.share({
            text: value,
            type: 'text'
        });
    };





    function shareimage() {

        var sharedModule = api.require('shareAction');
		
		
		    api.download({
                url: 'http://qr.liantu.com/api.php?bg=ffffff&fg=5f1bea&gc=a241cf&text='+dwzapi,
                savePath: 'fs://PerfectNetService.jpeg',
                report: true,
                cache: true,
                allowResume: true
            }, function(ret, err) {
                if(ret){
				
				/*
                    api.toast({
                        msg:'分享二维码已经保存',
						duration: 1000,
						location : 'middle' 
                    })
				*/
					
                }
                api.saveMediaToAlbum({
                    path: 'fs://PerfectNetService.jpeg'
                }, function(ret, err) {
                    
                });
            });
		
		
		
  //    alert(sharedModule);
        sharedModule.share({
            images: ['fs://PerfectNetService.jpeg'],
            type: 'image',
            thumbnail: "fs://PerfectNetService.jpeg",
             contentSize: {
                w: 100,
                h: 100
            }
        });
    };









  function share(){
  

  
    api.ajax({
        url: api_url+'/login/login/share.html',
        method: 'get',
        data: {
            values: {
				key: 'ikmovie.xyz',   //安全码
                uid: localStorage.getItem('user_id')
            }
        }
    },function(ret, err){
        if (ret) {
		
       //   copy = ret.msg;
      //    shama = ret.share;


	 		dwzapi = ret.dwzapi;  //短网址
			host = ret.host;  //当前域名
			app_Invitation_slogans = ret.app_Invitation_slogans;  //邀请标语
		
		//	user_share_ma = ret.user_share_ma;  //邀请码
			
			Registered_Gift_Time.innerHTML = ret.Registered_Gift_Time+' <span style="font-size: 0.8rem;margin-left: 10px;">Min</span>';  //注册赠送时间
	//		Commission_Ratio_Percentage.innerHTML = ret.Commission_Ratio_Percentage+'%的佣金奖励';  //返佣比例
	//		Commission_Ratio_PercentageA.innerHTML = ret.Commission_Ratio_Percentage;  //返佣比例A
	//		Commission_Ratio_PercentageB.innerHTML = ret.Commission_Ratio_PercentageB;  //返佣比例B
	//		user_headimgurl.innerHTML = '<img style="width: 65px; height: 65px;  border-radius: 100%; box-shadow: 0 2px 6px 0 rgba(0,0,0,0.3);" src="'+ret.user_headimgurl+'">';  //用户头像
	//		user_username.innerHTML = ret.user_username;  //用户名
	//		user_Total_Commission.innerHTML = ret.user_Total_Commission;  //已提现佣金
	//		Team_members.innerHTML = ret.Team_members;  //团队成员
	//		app_share_help.innerHTML = ret.app_share_help;  //APP帮助信息
			Invitation_points.innerHTML = ret.Invitation_points;  //邀请赠送积分 
			
			
			
			
			//提现列表
	//		var Withdrawals_record_frm = $api.byId('Withdrawals_record_list');//提现记录列表
	//		Withdrawals_record_data = ret.msg['Withdrawals_record_list'];
				

				
	/*			for(var i=0;i<Withdrawals_record_data.length;i++){ 
				
						//处理手机号中间隐藏
						var tel = Withdrawals_record_data[i].nickname;
						tel = "" + tel;
						var reg=/(\d{3})\d{4}(\d{4})/;
						var tel1 = tel.replace(reg, "$1****$2");
					
												

				
				var html='	<li>	<a><img src="">'+tel1+' 已经成功提现 '+Withdrawals_record_data[i].jine+' 元</a> </li>';
					$api.append(Withdrawals_record_frm,html);
				}

*/
            api.hideProgress();

        } else {
		
			api.hideProgress();
								
								
								
               api.toast({
                    msg: '信息获取失败',
                    duration: 2000,
					location : 'middle'   
                }); 

        }
    });


  }








//////////二维码//////////
  function erweima(){
  
  
    var dialogBox = api.require('dialogBox');
    dialogBox.webView({
        tapClose: false,
        path:  'http://qr.liantu.com/api.php?bg=ffffff&fg=5f1bea&gc=a241cf&text='+dwzapi,
        texts: {
            title: '专属邀请码：'+user_share_ma,
            leftBtnTitle: '关闭',
            rightBtnTitle: '保存相册'
        },
        styles: {
            bg: '#fff',
            corner: 5,
            w: 300,
            h: 380,
            title: {
                h: 44,
                size: 14,
                color: '#000'
            },
            upDividingLine: {
                width: 0.2,
                color: '#696969'
            },
            webView: {
                h: 300,
                bg: '#fff',
            },
            downDividingLine: {
                width: 0.2,
                color: '#696969'
            },
            left: {
                bg: 'rgba(0,0,0,0)',
                color: '#007FFF',
                size: 12
            },
            right: {
                bg: 'rgba(0,0,0,0)',
                color: '#007FFF',
                size: 12
            }
        }
    }, function(ret) {
        if (ret.eventType == 'left') {
            var dialogBox = api.require('dialogBox');
            dialogBox.close({
                dialogName: 'webView'
            });
        }else {
/*
          alert('请截屏后分享');
		  
		  */
		   var dialogBox = api.require('dialogBox');
            dialogBox.close({
                dialogName: 'webView'
            });
		  
			savePicture();   //保持图片
		   
        }
    });
  }
//////////二维码 //////////




function savePicture(){
            var timestamp = new Date().getTime()
            api.download({
				path: 'http://qr.liantu.com/api.php?bg=ffffff&fg=5f1bea&gc=a241cf&text='+dwzapi,
                savePath: 'fs://PerfectNetService'+timestamp+'.jpeg',
                report: true,
                cache: true,
                allowResume: true
            }, function(ret, err) {
                if(ret){
                    api.toast({
                        msg:'二维码已保存到相册',
						duration: 5000,
						location : 'middle' 
                    })
                }
                api.saveMediaToAlbum({
                    path: 'fs://PerfectNetService'+timestamp+'.jpeg'
                }, function(ret, err) {
                    
                });
            });
        }
		
		
	  	
		
		
//////////复制分享链接 //////////

  function copySet(){
    api.ajax({
        url: 'http://suo.im/api.htm?format=json&url='+dwzapi+'&key=5d79adb9b1a9c71d20af521e@13c666f4f75d74d90b6c11dc3201ee67&expireDate=2050-01-01',
        method: 'get'
    },function(ret, err){
        if (ret) {
		
	//	alert(JSON.stringify(ret.url));

	
          var clipBoard = api.require('clipBoard');
          clipBoard.set({
              value: app_Invitation_slogans+'：'+ret.url,  
          }, function(ret, err) {
              if (ret) {
                 api.toast({
                    msg: '邀请连接已复制',
                    duration: 2000,
					location : 'middle' 
                }); 
								api.hideProgress();
              } else {
              }
          });
		  
		
        } else {
          var clipBoard = api.require('clipBoard');
          clipBoard.set({
              value: app_Invitation_slogans+'：'+dwzapi
          }, function(ret, err) {
              if (ret) {
                 api.toast({
                    msg: '邀请连接已复制',
                    duration: 2000,
					location : 'middle' 
                }); 
								api.hideProgress();
              } else {

              }
          });

        }
    });
  }


//////////复制分享链接 //////////



  function openWin(name){
        var delay = 0;
        if(api.systemType != 'ios'){
            delay = 300;
        }
        api.openWin({
            name: ''+name+'',
            url: ''+name+'.html',
            bounces:false,
            delay: delay,
            slidBackEnabled:true,
            vScrollBarEnabled:false
        });
    }
	
	
	
	

		function Yield_rotation() {
			t = parseInt(x.css('top'));
			y.css('top', '25px');
			x.animate({
				top: t - 25 + 'px'
			}, 'slow');
			if (Math.abs(t) == h - 25) {
				y.animate({
					top: '0px'
				}, 'slow');
				z = x;
				x = y;
				y = z;
			}
			setTimeout(Yield_rotation, 5000);
		}
		$(document).ready(function() {
			$('.swap').html($('.news_li').html());
			x = $('.news_li');
			y = $('.swap');
			h = $('.news_li li').length * 25;
			setTimeout(Yield_rotation, 5000);
		})
	
	
	
	
      function toshare_poster(){


        api.openWin({
            name: 'share_poster_win',
            url: 'share_poster_win.html', 
        });


			//打开页面时 关闭当前页
		api.addEventListener({
         name:'viewdisappear'
     },function(){
         api.closeWin({
              name:api.winName
         });
     });	
		
    }	
	
	
	

</script>


</html>
